// angular
import {BrowserModule} from '@angular/platform-browser';
import {NgModule} from '@angular/core';
import {FormsModule, ReactiveFormsModule} from '@angular/forms';
import {HTTP_INTERCEPTORS, HttpClientModule} from '@angular/common/http';
import {BrowserAnimationsModule} from '@angular/platform-browser/animations';
import {registerLocaleData} from '@angular/common';
import en from '@angular/common/locales/en';
// 阿里
import {NgZorroAntdModule, NZ_I18N, zh_CN} from 'ng-zorro-antd';
// 自己
import {AppRoutingModule} from './app-routing.module';
import {AppComponent} from './app.component';
import {LoginComponent} from './base/login/login.component';
import {RegisterComponent} from './base/register/register.component';
import {HomeComponent} from './home/home.component';
import {BaseRouteFilter} from './base/base-route.filter';
import {DefaultPageComponent} from './home/default-page/default-page.component';
import {BaseHttpInterceptor} from './base/base-http.Interceptor';
import {ForgetComponent} from './base/forget/forget.component';
import {ShareFileComponent} from './base/share-file/share-file.component';
import {PipeModule} from './common/pipe/pipe.module';


registerLocaleData(en);

@NgModule({
  declarations: [
    AppComponent,
    LoginComponent,
    RegisterComponent,
    HomeComponent,
    DefaultPageComponent,
    ForgetComponent,
    ShareFileComponent
  ],
  imports: [
    BrowserModule,
    AppRoutingModule,
    FormsModule,
    HttpClientModule,
    BrowserAnimationsModule,
    ReactiveFormsModule,
    NgZorroAntdModule,
    PipeModule
  ],
  providers: [
    {provide: NZ_I18N, useValue: zh_CN},
    {provide: HTTP_INTERCEPTORS, useClass: BaseHttpInterceptor, multi: true},
    BaseRouteFilter
  ],
  bootstrap: [AppComponent]
})
export class AppModule {
}
